package com.sky.blog.dao.enums;

/**
 * @author sky  2022/3/23
 * @version 1.0
 */
public enum ResponseCode {
    /**
     * 处理成功
     */
    SUCCESS(200, "处理成功"),
    /**
     * 服务端代码错误
     */
    ERROR(500, "服务器错误");

    /**
     * 状态码
     */
    private final int code;
    /**
     * 状态信息
     */
    private final String message;

    ResponseCode(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }
}
